package org.alis.smallcc.designpatterns.behavior.observer.spring;

import org.springframework.context.event.EventListener;
import org.springframework.stereotype.Component;

@Component
public class PeopleApplicationListener {
	
	@EventListener(condition="!#event.getList().isEmpty()")
	public void handleEvent(PeopleBusEvent event)  {
	
		System.out.println("来了 "+this.hashCode());
		event.getList().forEach(System.out::println);
	}
}
